# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=p910nd
pkgver=0.97
pkgrel=2
pkgdesc="Non-spooling printer daemon"
url="https://github.com/kenyapcomau/p910nd"
arch="all"
license="GPL"
options="!check"
subpackages="$pkgname-doc $pkgname-openrc"
source="https://github.com/kenyapcomau/p910nd/archive/$pkgver/p910nd-$pkgver.tar.gz
$pkgname.initd
$pkgname.confd
fix-paths.patch"

build() {
	make
}

package() {
	install -Dm755 p910nd "$pkgdir"/usr/bin/p910nd
	install -Dm644 p910nd.8 "$pkgdir"/usr/share/man/man8/p910nd.8

	install -D -m755 "$srcdir"/$pkgname.initd \
		"$pkgdir"/etc/init.d/$pkgname
	install -D -m644 "$srcdir"/$pkgname.confd \
		"$pkgdir"/etc/conf.d/$pkgname
}

sha512sums="
162cb64ca79bfb1ce76b726e677ebba9f300c90e1e647625a7ee8db1d0c808a3f7b4ef9b139dfa2cfa7c8861082fe6dcdcc18636a0e0233010411b3746c1560c  p910nd-0.97.tar.gz
14064e928e887ac932e3d9ba82167f2bef13ba046e8cf8bda36a0790961cb346ad2258f8b00ff02a025c996061c7d94d2ef3e91a1e29d207784c49fb6aed296c  p910nd.initd
9a35dde6dabbe8131cfc18c47e9cdb54876f9c680f6badd1d6b399db459ae765a5fc388c549c9559088c5a056bf2e9c8417c778344b8bbf30756bde39ba4b021  p910nd.confd
81d528496a528d95fec474cfb569251293af506daae77893c232179f4e6d98cc897cdf574c3241b6c59611ca38b5fc2c86df8a81ef72b522b82c924127efa6cb  fix-paths.patch
"
